package br.com.datatraffic.fiscal.entidades;
// Generated 10/07/2009 10:49:54 by Hibernate Tools 3.2.0.b9


    
import java.util.ArrayList;
import java.util.List;
  
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

import org.hibernate.annotations.Cache;

/**
 * MarcaModelo generated by hbm2java
 */
@Entity
@Table(name="TBMARCA_MODELO")
public class MarcaModelo  implements java.io.Serializable {


     private Long id;
     private String nome;
     private String descricao;
     private List<Veiculo5> veiculos = new ArrayList<Veiculo5>(0);

    public MarcaModelo() {
    }

	
    public MarcaModelo(Long id, String nome) {
        this.id = id;
        this.nome = nome;
    }
    public MarcaModelo(Long id, String nome, String descricao, List<Veiculo5> veiculos) {
       this.id = id;
       this.nome = nome;
       this.descricao = descricao;
       this.veiculos = veiculos;
    }
   
     @Id 
     @SequenceGenerator(name = "SQ_TBMARCA_MODELO", sequenceName = "SQ_TBMARCA_MODELO", allocationSize=1)
     @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "SQ_TBMARCA_MODELO")
    @Column(name="MARCA_MODELO_ID", unique=true, nullable=false, precision=38, scale=0)
    public Long getId() {
        return this.id;
    }
    
    public void setId(Long id) {
        this.id = id;
    }
    
    @Column(name="NOME", nullable=false, length=50)
    public String getNome() {
        return this.nome;
    }
    
    public void setNome(String nome) {
        this.nome = nome;
    }
    
    @Column(name="DESCRICAO", length=100)
    public String getDescricao() {
        return this.descricao;
    }
    
    public void setDescricao(String descricao) {
        this.descricao = descricao;
    }
@OneToMany(     fetch=FetchType.LAZY, mappedBy="marcaModelo")
    public List<Veiculo5> getVeiculos() {
        return this.veiculos;
    }
    
    public void setVeiculos(List<Veiculo5> veiculos) {
        this.veiculos = veiculos;
    }



  // The following is extra code specified in the hbm.xml files
    private static final long serialVersionUID = 1L;
  // end of extra code specified in the hbm.xml files

}


